package com.ys.entity.base;

import java.util.Date;
import javax.persistence.Table;
import com.alibaba.fastjson.annotation.JSONField;
import com.ys.annotation.YsField;
import com.ys.entity.base.BaseEntity;
/**
*/
@Table(name="TB_BaseInfoArea", catalog="Id")
public class TbBaseInfoArea extends BaseEntity<TbBaseInfoArea> {

	@YsField(nameDataBase="Id", nameJava="id", typeDataBase="bigint")
	private Long id;
	@YsField(nameDataBase="Code", nameJava="code", typeDataBase="varchar")
	private String code;
	@YsField(nameDataBase="Name", nameJava="name", typeDataBase="varchar")
	private String name;
	@YsField(nameDataBase="Level", nameJava="level", typeDataBase="tinyint")
	private Integer level;
	@YsField(nameDataBase="HigherLevelPath", nameJava="higherLevelPath", typeDataBase="varchar")
	private String higherLevelPath;
	@YsField(nameDataBase="Pid", nameJava="pid", typeDataBase="bigint")
	private Long pid;
	@YsField(nameDataBase="Status", nameJava="status", typeDataBase="tinyint")
	private Integer status;
	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@YsField(nameDataBase="CreateTime", nameJava="createTime", typeDataBase="datetime")
	private Date createTime;
	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@YsField(nameDataBase="UpdateTime", nameJava="updateTime", typeDataBase="datetime")
	private Date updateTime;

	public Long getId() {
		return id;
	}
	public TbBaseInfoArea setId(Long id) {
		this.id = id;
		return this;
	}
	public String getCode() {
		return code;
	}
	public TbBaseInfoArea setCode(String code) {
		this.code = code;
		return this;
	}
	public String getName() {
		return name;
	}
	public TbBaseInfoArea setName(String name) {
		this.name = name;
		return this;
	}
	public Integer getLevel() {
		return level;
	}
	public TbBaseInfoArea setLevel(Integer level) {
		this.level = level;
		return this;
	}
	public String getHigherLevelPath() {
		return higherLevelPath;
	}
	public TbBaseInfoArea setHigherLevelPath(String higherLevelPath) {
		this.higherLevelPath = higherLevelPath;
		return this;
	}
	public Long getPid() {
		return pid;
	}
	public TbBaseInfoArea setPid(Long pid) {
		this.pid = pid;
		return this;
	}
	public Integer getStatus() {
		return status;
	}
	public TbBaseInfoArea setStatus(Integer status) {
		this.status = status;
		return this;
	}
	public Date getCreateTime() {
		return createTime;
	}
	public TbBaseInfoArea setCreateTime(Date createTime) {
		this.createTime = createTime;
		return this;
	}
	public Date getUpdateTime() {
		return updateTime;
	}
	public TbBaseInfoArea setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
		return this;
	}

	public static TbBaseInfoArea tbBaseInfoArea(
		String code,
		String name,
		Integer level,
		String higherLevelPath,
		Long pid,
		Integer status
			) {
		TbBaseInfoArea entity = new TbBaseInfoArea();
		entity.setCode(code);
		entity.setName(name);
		entity.setLevel(level);
		entity.setHigherLevelPath(higherLevelPath);
		entity.setPid(pid);
		entity.setStatus(status);
		return entity;
	}
}